home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
fortran
/
ftnchk26.zip
/
SOURCE
/
README
< prev
next >
Wrap
Text File
|
1993-02-01
|
6KB
|
170 lines
README file for Ftnchek Version 2.6.1
Author: Robert Moniot
Fordham University
New York, NY 10023 USA
Telephone: (212) 636-6331
Bitnet: MONIOT@FORDMULC
Internet: moniot@mary.fordham.edu
Date: January 1993
Ftnchek is written in a portable style of C. You must have a C
compiler for the machine on which you wish to run the program.
If the file you received is in the form of a "sh archive" or "shar"
file, and you received it by electronic mail, you should first
concatenate all parts in order (if it was sent in pieces), removing
any mail headers. If you received it by ftp, this step should not be
necessary. Next, if you have a UNIX system, simply feed it as input
to the program "sh" to unpack it automatically. If you do not have a
UNIX system, you will have to use your text editor to clip out each
file manually. You will observe that each line of every file has been
prefixed with the letter X, and all tabs have been converted to the
grave accent (ASCII code 60 hexadecimal). This was done to prevent
clobbering during shipment across network gateways. You should use
your editor to remove all initial X's and to change all grave accents
to tabs.
If the file you received is a Unix compressed tar file, you should
first unzip it using the Unix "uncompress" command, and then give it
as input to "tar" to unpack the files. For example, assuming the file
has been placed in the desired directory, and is named ftnchek.tar.Z, you
would give the two Unix commands
uncompress ftnchek.tar.Z
tar -xf ftnchek.tar
After accomplishing this step, you should find that you have received
the following set of source files:
ftnchek.c intrins.h symtab.h
ftnchek.h iokeywds.h symtab2.c
forlex.c prsymtab.c tokdefs.h
fortran.c symtab.c
You should also have received the following auxiliary files:
average.f build.com makefile makefile.mpw
average.out fortran.y makefile.tc
Documentation is in the files:
ftnchek.doc ftnchek.hlp ftnchek.man ftnchek.ps
The first is a flat text file. Ftnchek.hlp is for making a help
library for VMS systems. Ftnchek.man and ftnchek.ps are provided for
the convenience of those with access to nroff/troff or PostScript,
respectively.
VAX/VMS users should rename "AVERAGE.F" to "AVERAGE.FOR".
Once Ftnchek is working, you can test it by giving the command:
$ ftnchek -list -sym average
Then compare the output against the file "average.out". (Tabs and
trailing blanks have been removed from average.out due to shipping the
Ftnchek package across network gateways.)
To install Ftnchek, follow the instructions below for your operating
system.
(1) Unix
Give the command:
$ make
Note: System-specific compilation options are provided for some
systems. Users installing Ftnchek on one of these systems should
say "make system_name" where system_name is one of the following
words:
IBM-RS6000 SUNOS4.0
GENERIC SUNOS4.1
STARDENT ULTRIX-MIPS
Also, see the makefile for options that allow compiling with bigger
table sizes or accepting/rejecting certain syntax extensions.
(2) VAX/VMS
Give the command
$ @BUILD
After the program has been compiled, you must turn it into a
so-called "DCL foreign command" so that it can be invoked by
giving its name on a command line, instead of using the RUN
command. Do this with the command
$ FTNCHEK :== $disk:[directory]FTNCHEK
where you substitute the disk and directory names where the file
FTNCHEK.EXE resides. This command must be executed once per
login. It is suggested you put this command into your LOGIN.COM
file.
The BUILD procedure also creates a VMS help library named
FTNCHEK.HLB. To access it from the VMS HELP command, you must
give the command
$ DEFINE HLP$LIBRARY disk:[directory]FTNCHEK.HLB"
Again, this command must be executed once per login to have effect.
(3) MS-DOS with Turbo C
Rename the file "makefile.tc" to "makefile" and then give the
command:
C> MAKE
(4) Macintosh Programmer's Workshop (MPW)
Rename the file "makefile.mpw" to "makefile". Edit the file,
changing character '+' to CHAR(182), option-d on the Macintosh
keyboard; and the character '/' to CHAR(196), option-f. Then
use the "make" command to create Ftnchek.
(5) Other systems
It should suffice simply to compile all the ".c" files and link
them. The only differences among the versions for different
operating systems have to do with the use of "/" vs. "-" as an
option prefix, and the default filename extension ".FOR" vs. ".f".
Selection among these options is done by defining a macro name for
each system. The VAX/VMS compiler pre-defines the macro name
"VMS", while the Turbo C compiler pre-defines "__TURBOC__".
Compilation without defining either of these macro names is the
same as compiling with "UNIX" defined.
To allow "/" as an option prefix, you can define the macro name
"VMS", either as a commandline option to the compiler, or by
altering the file ftnchek.h: just remove the commenting-out of
the appropriate #define command found there. In any case, "-" is
always allowed as an option prefix.
The default extension ".FOR" is assumed for VMS or Turbo C, ".f"
for all others, unless you define the macro name
"DEF_SRC_EXTENSION" otherwise on the compiler commandline or in
ftnchek.h. Other default values of Ftnchek's built-in parameters
can be similarly modified on the compiler commandline. See
ftnchek.h for details.
If your Fortran compiler supports many of the common I/O extensions
found in VAX Fortran, you can compile the source using the compiler
flag -DVMS_IO to cause Ftnchek to accept these extensions without
assuming all other the VAX Fortran extensions and conventions. The
VAX I/O extensions include, for instance several additional control
keywords for the OPEN statement, such as CARRIAGECONTROL, READONLY,
etc.